﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace Hardware
{
    public interface IMeter
    {
        event EventHandle DataReceived;
        event StatusEventHandle StatusChanged;
        event EventShowHexData ShowHexData;

        bool IsOpen { get; set; }            // 是否打开状态
        bool ShowHexFlag { get; set; }      //显示Hex数据，缺省为假

        void Close();
        void Open();

    }

    public delegate void EventShowHexData(string hexData);

    public delegate void EventHandle(double weight, object sender);    

    public delegate void StatusEventHandle(string param, object sender);

}
